package com.itc.bi.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

/**
 * 数据加工详情
 * @TableName tb_data_process_info
 */
@TableName(value ="tb_data_process_info")
@Data
@Api(value = "数据加工详情")
public class DataProcessInfoEntity implements Serializable {

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    /**
     *
     */
    @TableId(type = IdType.ASSIGN_ID)
    private Long id;

    /**
     * 数据加工id
     */
    @TableField(value = "dp_id")
    @ApiModelProperty(value = "数据加工id")
    private Long dpId;

    /**
     * 数据加工名称(过滤、计算字段、分组赋值、汇总列、数据集合并、聚合指标、指标切片)
     */
    @ApiModelProperty(value = "数据加工名称(过滤、计算字段、分组赋值、汇总列、数据集合并、聚合指标、指标切片)")
    private String name;

    /**
     * 类型(数据加工process，聚合指标aggregate)
     */
    @ApiModelProperty(value = "类型(数据加工process，聚合指标aggregate)")
    private String type;

    /**
     * 原始参数
     */
    @ApiModelProperty(value = "原始参数")
    @TableField(value = "original_parameter")
    private String originalParameter;

    /**
     * 参数值(sql语句完整)
     */
    @ApiModelProperty(value = "参数值(sql语句完整)")
    @TableField(value = "parameter_values")
    private String parameterValues;

    /**
     * 数据加工顺序
     */
    @ApiModelProperty(value = "数据加工顺序")
    private Integer orderNum;

    @ApiModelProperty(value = "数据加工生成表")
    private String processTable;

    /**
     * 描述
     */
    @ApiModelProperty(value = "描述")
    private String description;

    /**
     * 创建时间
     */
    @ApiModelProperty(value = "创建时间")
    @TableField(value = "create_time",fill = FieldFill.INSERT)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    private Date createTime;

    /**
     * 更新时间
     */
    @ApiModelProperty(value = "更新时间")
    @TableField(value = "update_time",fill = FieldFill.INSERT_UPDATE)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    private Date updateTime;

    /**
     * 创建人
     */
    @ApiModelProperty(value = "创建人")
    @TableField(value = "create_by",fill = FieldFill.INSERT)
    private String createBy;

    /**
     * 更新人
     */
    @ApiModelProperty(value = "更新人")
    @TableField(value = "update_by",fill = FieldFill.INSERT_UPDATE)
    private String updateBy;

    @ApiModelProperty(value = "新增列json")
    @TableField(value = "column_json")
    private String columnJson;


    @ApiModelProperty(value = "使用到的字段")
    @TableField(value = "user_field")
    private String userField;

    @ApiModelProperty(value = "合并数据集ID")
    @TableField(value = "union_dt_id")
    private Long unionDtId;

    @ApiModelProperty(value = "合并数据集数仓表名")
    @TableField(exist = false)
    private String unionTableName;

}
